package cn.itcast.test;

public class test {


    public static void main(String[] args) {
        ListNode head = new ListNode(3);
        ListNode point = head;
        int[] arr = {2,0,-4};
        for(int i=0;i<3;i++) {
            ListNode node = new ListNode(arr[i]);
            point.next=node;
            point = node;
        }

        while(head!=null){
            System.out.println(head.val);
            head = head.next;
        }

    }

}
